<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>
	
<%-- <%@ page import="javax.servlet.http.HttpServletRequest" %>  --%>
<%@ page import="java.util.UUID" %> 
<%@ page import="com.easyattendance.services.LoginService" %> 
<%@ page import="com.easyattendance.model.User" %> 

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Activation Successful</title>
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
<%-- <%@include file="includeFiles.jsp" %> --%>
	<meta http-equiv="content-type" content="text/html; charset=utf-8" />
	<meta name="description" content="" />
	<meta name="keywords" content="" />
	<link
		href="http://fonts.googleapis.com/css?family=Source+Sans+Pro:400,400italic,700|Open+Sans+Condensed:300,700"
		rel="stylesheet" />
	<script src="<%=request.getContextPath()%>/public/js/jquery.min.js"></script>
	<script src="<%=request.getContextPath()%>/public/js/skel.min.js"></script>
	<script src="<%=request.getContextPath()%>/public/js/skel-panels.min.js"></script>
	<script src="<%=request.getContextPath()%>/public/js/init.js"></script>
	<script src="<%=request.getContextPath()%>/public/js/validate.js"></script>
			
	<link rel="stylesheet" href="<%=request.getContextPath()%>/views/css/skel-noscript.css" />
	<link rel="stylesheet" href="<%=request.getContextPath()%>/views/css/style.css" />
	<link rel="stylesheet" href="<%=request.getContextPath()%>/views/css/style-desktop.css" />
	<link rel="stylesheet" href="<%=request.getContextPath()%>/views/css/style-wide.css" />
	
	<!--[if lte IE 9]><link rel="stylesheet" href="css/ie9.css" /><![endif]-->
	<!--[if lte IE 8]><script type="text/javascript" src="<%=request.getContextPath()%>/public/js/html5shiv.js"></script><link rel="stylesheet" href="css/ie8.css" /><![endif]-->
	<!--[if lte IE 7]><link rel="stylesheet" href="css/ie7.css" /><![endif]-->
	
</head>

<!--
		Note: Set the body element's class to "left-sidebar" to position the sidebar on the left.
		Set it to "right-sidebar" to, you guessed it, position it on the right.
	-->
<body class="left-sidebar">

	<!-- Wrapper -->
 <div id="wrapper">

		<!-- Content -->
		<div id="content">
			<div id="content-inner">				
				<div id="login_content">
				
				<%
		     		//String query_str=request.getQueryString();
					String token=request.getParameter("token");  //get secret key from query string
		     		System.out.println("token="+token);
						
					 LoginService loginService=new LoginService();
					
					 loginService.updateEnabled(token);
						  
					 //generate new secret key to update the existing one
					 String secret_key = UUID.randomUUID().toString();
					 loginService.updateSecretKey(token,secret_key);
				%>
						
				<h2>Your account has been successfully activated! </h2><br>
					To login <a href="../views/login.jsp">Click Here</a>
	
			
				</div>
				
			</div>
		</div>

			<!-- Sidebar -->
		<div id="sidebar">

			<!-- Logo -->
			<div id="logo">
				<!-- <h1>Attendance</h1> -->
			</div>
			<h2 style="text-align: center;">Easy Attendance</h2>

			<!-- Text -->
			<section class="is-text-style1">
			<div class="inner">
				<p>"Intelligent way to manage attendance."</p>
			</div>
			</section>

			<!-- Copyright -->
			<div id="copyright">
				<p>
					&copy; 2014 Sysoftni Solutions.<br /> <a
						href="http://www.sysoftni.com" target="_blank">www.sysoftni.com</a>
				</p>
			</div>

		</div>

 </div>
	
</body>
</html>

